#ifndef EVENT_HANDLER_H
#define EVENT_HANDLER_H

#include "i_socket.h"
#include "model/dom.h"
#include "network.h"
#include "notifier.h"

#include <boost/shared_ptr.hpp>

namespace network {
	typedef unsigned int event_type;
	enum {
		CONNECT = 0,
		RECEIVE = 2
	};

	class event_handler : public network::notifier {
	public:
		event_handler() {}
		virtual ~event_handler() {}

		virtual network::event_type get_type() const = 0;
		virtual boost::shared_ptr<const network::i_socket> 
			get_socket() const = 0;
		virtual void handle_event(
			boost::shared_ptr<network::event> n) = 0;
	private:
	};
}

#endif
